<%@ page import="java.sql.*, studentportal.*"%>
<%@taglib uri="http://java.sun.com/jstl/core" prefix="c"%>
<html>

<body topmargin=0 leftmargin=0>

 
<table border="0" width="100%" bordercolorlight="#666666" bordercolordark="#000000">
  <tr>
    <td width="100%"><img border="0" src="StdPrtlbanner.jpg" width="846" height="65">&nbsp;</td>
  </tr>
</table>
<table border="0" width="100%">
  <tr>
    <td width="23%">
      <p align="center"><a href="AdminStudentHome.html">Students</a></td>
    <td width="23%">
      <p align="center"><a href="AdminFacultyHome.html">Faculties</a></td>

    <td width="20%">
      <p align="center"><a href="AdminNotificaiton.jsp">Notifications</a></td>

    <td width="20%">
      <a href="AdminDeptHome.html">Departments</a></td>

    <td width="20%">
      <p align="center"><a href="AdminCourseHome.html">Courses</a></td>

    <td width="20%">
      <p align="center"><a href="AdminSemesterHome.html">Semesters</a></td>

    <td width="20%">
      <p align="center"><a href="AdminSubjectHome.html">Subjects</a></td>

    <td width="20%">
      <a href="AdminDesignationHome.html">Designation</a></td>

	  <td width="20%">
      <p align="center"><a href="Home.html">Home</a></td>
  </tr>
</table>





<%
					
					Connection con=MySQLDriver.getConnection(); 
					Statement st=con.createStatement();
					System.out.println("After Statement");
					String sid=(String)session.getAttribute("StudentId");
					System.out.println("STRING"+sid);
					String str="select student_id, student_name, student_address, student_dob, student_phone, student_email, student_admt_date, student_login_name, student_login_status,(select course_master.course_name from course_master where course_master.course_id = student_master.course_id) from student_master where student_id='"+sid+"'";
					str="select student_id, student_name, student_admt_date, (select course_master.course_name from course_master where course_master.course_id = student_master.course_id),book_master.book_name, book_master.author,book_master.edition  from student_master, book_master where student_id="+request.getParameter("SID")+" and book_id="+request.getParameter("BID");
					ResultSet rs=st.executeQuery(str);
					rs.next();
					//Student stu=(Student)session.getAttribute("Student");
%>
<p align="center">&nbsp;</p>
<form method="POST" action="Admin_Accepted_Book.jsp">
  <input type="hidden" name="SID" value='<%=request.getParameter("SID")%>'/>
  <input type="hidden" name="BID" value='<%=request.getParameter("BID")%>'/>
  <input type="hidden" name="BBID" value='<%=request.getParameter("BBID")%>'/>
  <div align="center">
    <center>
    <table border="1" width="68%" bordercolor="#0000FF">
    </center>
    <tr>
      <td width="50%" valign="middle" align="left">
        <p align="left">Student No</td>
      <td width="50%"><input type="text" name="sid" size="20" tabindex="1" value="<%=rs.getString(1)%>" disabled="true"></td>	
      </tr>
    </center>
    <tr>
      <td width="50%" valign="middle" align="left">
        <p align="left">Name</td>
      <td width="50%"><input type="text" name="sname" size="20" tabindex="2" value="<%=rs.getString(2)%>" disabled="true"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Admission Date</td>
        <td width="50%"><input type="text" name="sdoa" size="20" tabindex="7" value="<%=rs.getDate(3)%>" disabled="true"></td>
      </tr>
	  <tr>
        <td width="50%" valign="middle" align="left">Course Name</td>
        <td width="50%"><input type="text" name="slogin" size="20" tabindex="8" value="<%=rs.getString(4)%>" disabled="true"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Book Name</td>
        <td width="50%"><input type="text" name="slogin" size="20" tabindex="8" value="<%=rs.getString(5)%>" disabled="true"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Book Author</td>
        <td width="50%"><input type="text" name="slogin" size="20" tabindex="8" value="<%=rs.getString(6)%>" disabled="true"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Book Edition</td>
        <td width="50%"><input type="text" name="slogin" size="20" tabindex="8" value="<%=rs.getString(7)%>" disabled="true"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Valid From</td>
        <td width="50%"><input type="text" name="FROM" size="20" tabindex="8"></td>
      </tr>
      <tr>
        <td width="50%" valign="middle" align="left">Valid To</td>
        <td width="50%"><input type="text" name="TO" size="20" tabindex="8"></td>
      </tr>
          <tr>
      <td width="100%" colspan="2" background="file:///C:/Documents%20and%20Settings/Administrator/My%20Documents/My%20Pictures/strbkgde.gif" height="24">
        <p align="center"><input type="submit" value="Accept" name="action"></td>
        
    </tr>
      
    </table>
    </center>
  </div>
</form>
<p align="left">&nbsp;</p>
<%con.close();%>

</body>

</html>
